<!-- {if $member_from eq 'seller'}-->
		{include file=member.header.html}
        <!--{else}-->
       {include file=buyer.header.html}
        <!--{/if}-->
<script type="text/javascript">
//注册表单验证
$(function(){
    $('#binding_form').validate({
        errorPlacement: function(error, element){
            $(element).next('.field_notice').hide();
            $(element).after(error);
        },
        success       : function(label){
            label.addClass('validate_right').text('OK!');
        },
        onkeyup: false,
        rules : {           
            phone_mob : {
                required : true,
                isMobile    : true
            },
            mobile_verification_code : {
                required : true,
                isCode    : true,
                remote   : {
                    url : 'index.php?app=send_mobile&act=chack_verification_code',
                    type: 'post',
                    data:{
                        mobile_verification_code : function(){
                            return $('#mobile_verification_code').val();
                        }
                    }
                }
            }
            
        },
        messages : {
            phone_mob : {
                required : '手机号码不能为空',
                isMobile    : '手机号码不正确'
            },
            mobile_verification_code : {
                required : '验证码不能为空',
                isCode    : '验证码为6位的数字',
                remote   : '验证码不正确'
            }
            
        }
    });   
    
    $("#phone_mob").blur(function(){
        var phone_mob = $("#phone_mob").val();        
        if(phone_mob && userValidate.chacMobile(phone_mob))
        {
            $('#send_mobile_code').attr("disabled", false);
                    
        }
        
  });
  
  $("#send_mobile_code").click(function(){
        var phone_mob = $("#phone_mob").val();  
            
        if(phone_mob && userValidate.chacMobile(phone_mob))
        {
           userValidate.setMobileSession(phone_mob);
           userValidate.sendMobile(phone_mob,'binging_mobile');
           return;

        }
  });
  
});
</script>

<!-- 内容 -->
<div class="content f-cb">
  <!-- 当前位置 -->
  {include file=path.html}
  <!-- 内容左边栏 -->
  <!-- {if $member_from eq 'seller'}-->
		{include file=member.menu.html}
        <!--{else}-->
        {include file=member.menu.buyer.html}
        <!--{/if}-->
  <!-- 内容右边栏 -->
  <!-- 第一步 -->
  <!-- {if $step eq 1}--> 
  <div class="right_content">
  <div class="t_1">绑定手机</div>
  <div class="step_set bg_png step_set_current_2_1"><span class="step_set_2_1 current">1 手机验证</span><span class="step_set_2_2">2 绑定完成</span></div>
  </div>
  
  <div class="con-receive-r b-radius safety_content">
    <div class="eject_con">
      <div class="add safety_modify_password">
        <form method="post"  action="index.php?app=send_mobile&act=set_binding_mobile" id="binding_form">
          <ul>
            <li>
              <h3>手机号码: </h3>
              <p><input type="text" class="text width_normal b-radius" name="phone_mob" maxlength="11" id="phone_mob" value="" /></p>
            </li>
            <li>
              <h3>验证码: </h3>
              <p>
                <input type="text" class="text width2 b-radius" name="mobile_verification_code" maxlength="6" id="mobile_verification_code" disabled="disabled" />
                &nbsp;&nbsp;
                <input class="button_on b-radius" type="button" value="获取短信验证码" id="send_mobile_code" disabled="disabled" />
                </p>
            </li>           
          </ul>
          <p style="display:none;padding-left: 146px;" id="show_error" >验证码已经发送,敬请查看!</p> 
          <div class="submit submit_1" style="padding-left:150px;">
            <input type="submit" class="subbtn b-radius" value="提交"  id="send_submit" disabled="disabled" />
            </div>          
        </form>
      </div>
    </div>
  </div>
  <!--{/if}-->
  <!-- 完成 -->
  <!-- {if $step eq 2}--> 
  <div class="right_content">
  <div class="t_1">绑定手机</div>
  <div class="step_set bg_png step_set_current_2_2"><span class="step_set_2_1">1 手机验证</span><span class="step_set_2_2 current">2 绑定完成</span></div>
  </div>
  <div class="con-receive-r b-radius safety_content">
    <div class="eject_con">
      <div class="add safety_modify_password">
        <div class="set_succeed"><h3>手机绑定成功 <br /><span class="coe6">新绑定手机：{$accout_data.binding_mobile}</span></h3><p class="linkbtn"><a href="index.php?app=account_security&from={$member_from}">返回安全设置</a></p></div>
      </div>
    </div>
  </div>
  <!--{/if}-->
</div>
<!-- 页脚 -->
{include file=footer.html}